package com.rams.jhms;

import com.rams.jhms.fs.FSConfigWorker;
import com.rams.jhms.l18n.LocalStrings;

public class Config {
	/**
	 * System parameter for using in MigLayout manager for enabling or disabling
	 * layout debug mode.
	 * If 1 -- debug mode enable, if 0 -- disable
	 */
	public static final int layoutDebug = 0;
	
	/**
	 * System parameter for enabling or disabling application errors loging
	 * Use true or false (enable/disable)
	 */
	public static final boolean appLogingEnable = true;
	
	public static final String defLogProps = "src/log4j.xml";
	
	/**
	 * Minimal application width
	 */
	public static final int minAppWidth = 400;
	/**
	 * Minimal application height
	 */
	public static final int minAppHeight = 400;
	
	/**
	 * 
	 */
	public static final boolean dbEmbeded = false;
	
	public static final String configFileName = "config.xml";
	
	/**
	 * System parameter for configure system localization.
	 * For use localization you must write specific class in <code>com.rams.jhms.l18n</code> package.
	 */
	public static LocalStrings local;
	
	/**
	 * Path to local folder where media library placed on disk
	 */
	public static String mediaDbPath;
	
	/**
	 * Save application properties to application config file
	 */
	public static void save() {
		(new FSConfigWorker()).save();
	}

	/**
	 * Load application parameters from a file
	 */
	public static void load() {
		(new FSConfigWorker()).load();
	}
}
